<div id="delete-topic" class="content-section">
  <h2>Delete Topic?</h2>
  <p class="confirmation">Are you sure you want to delete this topic?</p>

  <p>This topic has been held <%= pluralize(@topic.past_sessions.size, 'time') %>.</p>
  
  <%= link_to "Delete This Topic", @topic, 
        method: :delete,
        data: { confirm: "Are you sure you want to delete this topic?" }, 
        class: 'delete-button register-button' 
  %>
  
  <%= link_to "Cancel", @topic, :class => "register-button" %>
  
</div>

<div id="past-session-details" class="session-list content-section">
  <% if authorized?(@topic) && @topic.past_sessions.present? %>
    <h2>Past Sessions</h2>
    <%= session_list(@topic.past_sessions.reverse) %>
  <% end %>
</div>
